﻿using LDM.Business.Repository.Repository.Interfaces;
using Logs;
using Microsoft.AspNetCore.Mvc;

namespace LDM.Business.Service.Controllers
{
    /// <summary>
    /// 系统配置服务
    /// </summary>
    [ApiController]
    [Route("[Controller]/[action]"), Produces("application/json")]
    public class SystemConfigController : Controller
    {
        private readonly ISystemConfigRepository _systemConfigRepository;

        private readonly ILog _log;
        public SystemConfigController(ISystemConfigRepository systemConfigRepository, ILog log)
        {
            _systemConfigRepository = systemConfigRepository;
            _log = log;
        }

        /// <summary>
        /// 创建系统配置表
        /// </summary>
        /// <returns></returns>
        [HttpPost]
        public IActionResult CreateTable()
        {
            _systemConfigRepository.CreateTable();
            return Ok("Success");
        }
    }
}
